package com.zxzhu.joyread.View;

import android.content.Intent;
import android.widget.TextView;

import com.avos.avoscloud.AVOSCloud;
import com.avos.avoscloud.AVUser;
import com.zxzhu.joyread.Common.BaseActivity;
import com.zxzhu.joyread.R;

public class StartView extends BaseActivity {

    private TextView textView;

    @Override
    protected void initData() {
        AVOSCloud.initialize(this, "NEIXG8KwR1mgSs3QlQkmVkgG-gzGzoHsz", "XvFsXMcdQ3Kx1cUFe9hhOcOV");
        textView = $(R.id.start_tv);
        Class c;
        if(AVUser.getCurrentUser() == null){
            c = WelcomeView.class;
        }else{
            c = MainView.class;
        }
        Intent intent = new Intent(this,c);
        startActivity(intent);
        finish();
    }

    @Override
    protected int getContentViewId() {
        return R.layout.activity_start_view;
    }

}
